export default function TodoItem(todo) {
  const oLi = document.createElement('li');
  oLi.innerHTML = `
    <input 
      type="checkbox"
      ${todo.completed ? 'checked' : ''}
      data-id="${todo.id}"
    />
    <span 
      style="
        text-decoration: ${todo.completed ? 'line-through' : ''}
      "
    >
      ${todo.content}
    </span>
    <button data-id="${todo.id}">Delete</button>
  `;
  return oLi;
}
